using System.Runtime.InteropServices;
using Baula.TextGen.ComAndVbeIntegration.ComInterfaces;

namespace Baula.TextGen.ComAndVbeIntegration
{
    [ComVisible(true)]
    [Guid("F9F9DA0F-1779-4780-ADC5-C669EEB8AA0F")]
    [ClassInterface(ClassInterfaceType.None)]
    public class Part : Framework.Part, IPartForCom
    {
        internal Part(Framework.PartTemplate partTemplate) 
            : base(partTemplate)
        { }

        void IPartForCom.SetValueForPlaceholder(string placeholderName, string value)
        {
            ValuesForPlaceholders[placeholderName] = value;
        }

        public string GetValueForPlaceholders(string placeholderName)
        {
            return ValuesForPlaceholders[placeholderName];
        }
    }
}